package com.ktjiaoyu.crm.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.ktjiaoyu.crm.pojo.Role;
import org.apache.ibatis.annotations.Param;

public interface RoleService extends IService<Role> {

    Page<Role> selectRolePages(Page page, String roleName);

    /**
     * 新增或修改角色权限
     * @param role
     * @param rightCodes
     * @return
     */
    boolean saveRoleAndRight(Role role,String[] rightCodes);

    Role findRoleByUserId(@Param("usrId") Long usrId);

}
